-
Notifications
You must be signed in to change notification settings - Fork 1k
Support custom exception handling #14493
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support custom exception handling #14493
Conversation
|
🔧 The result from spotlessApply was committed to the PR branch. |
laurit
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line 90 in fd74eb8
| attributes.put(ExceptionAttributes.EXCEPTION_TYPE, throwable.getClass().getName()); |
| StringWriter writer = new StringWriter(); | ||
| throwable.printStackTrace(new PrintWriter(writer)); | ||
| attributes.put(ExceptionAttributes.EXCEPTION_STACKTRACE, writer.toString()); | ||
| if (builder instanceof ExtendedLogRecordBuilder) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://github.com/open-telemetry/opentelemetry-java-instrumentation/blob/main/conventions/src/main/kotlin/io.opentelemetry.instrumentation.library-instrumentation.gradle.kts adds dependency to instrumentation-api-incubator that pulls in opentelemetry-api-incubator so ExtendedLogRecordBuilder is always present. Really this instrumentation doesn't use the instrumentation api.
380f60f to
2e553f7
Compare
|
🔧 The result from spotlessApply was committed to the PR branch. |
4544a29 to
40c7dd3
Compare
|
🔧 The result from spotlessApply was committed to the PR branch. |
Resolves #14485